package com.lipaluma.test.db.internal.assertions;

import com.lipaluma.test.db.internal.assertions.Column.Builder;

/**
 * Type of columns managed by the framework
 * @author Mario
 *
 */
public enum ColumnType {
	/**
	 * String column
	 */
	STRING {
		@Override
		public StringColumn.Builder createColumnBuilder(String request) {
			return StringColumn.builder(request);
		}
	}, 
	/**
	 * Boolean column
	 */
	BOOLEAN {
		@Override
		public BooleanColumn.Builder createColumnBuilder(String request) {
			return BooleanColumn.builder(request);
		}
	}, 
	/**
	 * Integer column
	 */
	INT {
		@Override
		public LongColumn.Builder createColumnBuilder(String request) {
			return LongColumn.builder(request);
		}
	}, 
	/**
	 * Long column
	 */
	LONG {
		@Override
		public LongColumn.Builder createColumnBuilder(String request) {
			return LongColumn.builder(request);
		}
	},
	/**
	 * Double column
	 */
	DOUBLE {
		@Override
		public DoubleColumn.Builder createColumnBuilder(String request) {
			return DoubleColumn.builder(request);
		}
	}, 
	/**
	 * Float column
	 */
	FLOAT {
		@Override
		public DoubleColumn.Builder createColumnBuilder(String request) {
			return DoubleColumn.builder(request);
		}
	}, 
	/**
	 * Character column
	 */
	CHAR {
		@Override
		public StringColumn.Builder createColumnBuilder(String request) {
			return StringColumn.builder(request);
		}
	}, 
	/**
	 * Date column
	 */
	DATE {
		@Override
		public Builder<?> createColumnBuilder(String request) {
			return DateColumn.builder(request);
		}
	}, 
	/**
	 * DateTime column
	 */
	DATETIME {
		@Override
		public Builder<?> createColumnBuilder(String request) {
			return DateTimeColumn.builder(request);
		}
	}, 
	/**
	 * String column that correspond a pattern
	 */
	PATTERN{
		@Override
		public Builder<?> createColumnBuilder(String request) {
			return PatternColumn.builder(request);
		}
	};

	public abstract Column.Builder<?> createColumnBuilder(String request);
}
